@extends('layouts.admin')

@section('content')
        <!--面包屑导航 开始-->
<div class="crumb_warp">
    <!--<i class="fa fa-bell"></i> 欢迎使用登陆网站后台，建站的首选工具。-->
    <i class="fa fa-home"></i> <a href="{!! url('/admin/info') !!}">首页</a> &raquo; 添加文章
</div>
<!--面包屑导航 结束-->

<!--结果集标题与导航组件 开始-->
<div class="result_wrap">
    <div class="result_title">
        <h3>快捷操作</h3>
    </div>
    <div class="result_content">
        <div class="short_wrap">
            <a href="{!! url('/admin/article/create') !!}"><i class="fa fa-plus"></i>新增文章</a>
            <a href="{!! url('/admin/article') !!}"><i class="fa fa-fw fa-list-ul"></i>文章列表</a>
        </div>
    </div>
</div>
<!--结果集标题与导航组件 结束-->

<div class="result_wrap">
    <form action="{!! url('/admin/article') !!}" method="post">
        <table class="add_tab">
            <tbody>
            <tr>
                <th width="120"><i class="require">*</i>分类：</th>
                <td>
                    <select name="pid">
                        <option value="0">==请选择==</option>
                        <option value="19">精品界面</option>
                        <option value="20">推荐界面</option>
                    </select>
                </td>
            </tr>
            <tr>
                <th><i class="require">*</i>标题：</th>
                <td>
                    <input type="text" size="50" maxlength="120" name="title">
                    <span><i class="fa fa-exclamation-circle yellow"></i>标题可以写120个字</span>
                    @if($errors->has('title'))
                        <p class="colorRed">{!! $errors->first('title') !!}</p>
                    @endif
                </td>
            </tr>
            <tr>
                <th>作者：</th>
                <td>
                    <input type="text" name="author">
                    <span><i class="fa fa-exclamation-circle yellow"></i>这里是默认长度</span>
                </td>
            </tr>
            <tr>
                <th><i class="require">*</i>来源：</th>
                <td>
                    <input type="text" name="source">
                    <span><i class="fa fa-exclamation-circle yellow"></i>这里是短文本长度</span>
                </td>
            </tr>
            <tr>
                <th><i class="require">*</i>缩略图：</th>
                <td>
                    <input type="text" size="50" name="art_thumb">
                </td>
            </tr>
            <tr>
                <th></th>
                <td></td>
            </tr>
            <tr>
                <th>描述：</th>
                <td>
                    <textarea name="description"></textarea>
                </td>
            </tr>
            <tr>
                <th>详细内容：</th>
                <td>
                    <script id="editor" name="content" type="text/plain" style="width:860px;height:500px;"></script>
                    <input type="hidden" name="content">
                    <script type="text/javascript">
                        var ue = UE.getEditor('editor');
                    </script>
                    <style>
                        .edui-default{line-height: 28px;}
                        div.edui-combox-body,div.edui-button-body,div.edui-splitbutton-body
                        {overflow: hidden; height:20px;}
                        div.edui-box{overflow: hidden; height:22px;}
                    </style>
                </td>
            </tr>
            <tr>
                <th>是否推荐到首页：</th>
                <td>
                    <label class="label-display"><input type="radio" name="isIndex" checked value="1">是</label>
                    <label class="label-display"><input type="radio" name="isIndex" value="0">否</label>
                </td>
            </tr>
            <tr>
                <th></th>
                <td>
                    <input type="submit" value="提交">
                    <input type="button" class="back" onclick="history.go(-1)" value="返回">
                </td>
            </tr>
            </tbody>
        </table>
        {!! csrf_field() !!}
    </form>
</div>
@endsection
@section('js')
<script type="text/javascript" charset="utf-8" src="{{asset('backsted/ueditor/ueditor.config.js')}}"></script>
<script type="text/javascript" charset="utf-8" src="{{asset('backsted/ueditor/ueditor.all.min.js')}}"> </script>
<script type="text/javascript" charset="utf-8" src="{{asset('backsted/ueditor/lang/zh-cn/zh-cn.js')}}"></script>
@endsection